package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.WorkOrderNameDoseValueMapper;
import com.ruoyi.system.domain.WorkOrderNameDoseValue;
import com.ruoyi.system.service.IWorkOrderNameDoseValueService;
import com.ruoyi.common.core.text.Convert;

/**
 * 工单剂量Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-10-29
 */
@Service
public class WorkOrderNameDoseValueServiceImpl implements IWorkOrderNameDoseValueService 
{
    @Autowired
    private WorkOrderNameDoseValueMapper workOrderNameDoseValueMapper;

    /**
     * 查询工单剂量
     * 
     * @param id 工单剂量主键
     * @return 工单剂量
     */
    @Override
    public WorkOrderNameDoseValue selectWorkOrderNameDoseValueById(Long id)
    {
        return workOrderNameDoseValueMapper.selectWorkOrderNameDoseValueById(id);
    }

    /**
     * 查询工单剂量列表
     * 
     * @param workOrderNameDoseValue 工单剂量
     * @return 工单剂量
     */
    @Override
    public List<WorkOrderNameDoseValue> selectWorkOrderNameDoseValueList(WorkOrderNameDoseValue workOrderNameDoseValue)
    {
        return workOrderNameDoseValueMapper.selectWorkOrderNameDoseValueList(workOrderNameDoseValue);
    }

    /**
     * 新增工单剂量
     * 
     * @param workOrderNameDoseValue 工单剂量
     * @return 结果
     */
    @Override
    public int insertWorkOrderNameDoseValue(WorkOrderNameDoseValue workOrderNameDoseValue)
    {
        return workOrderNameDoseValueMapper.insertWorkOrderNameDoseValue(workOrderNameDoseValue);
    }

    /**
     * 修改工单剂量
     * 
     * @param workOrderNameDoseValue 工单剂量
     * @return 结果
     */
    @Override
    public int updateWorkOrderNameDoseValue(WorkOrderNameDoseValue workOrderNameDoseValue)
    {
        return workOrderNameDoseValueMapper.updateWorkOrderNameDoseValue(workOrderNameDoseValue);
    }

    /**
     * 批量删除工单剂量
     * 
     * @param ids 需要删除的工单剂量主键
     * @return 结果
     */
    @Override
    public int deleteWorkOrderNameDoseValueByIds(String ids)
    {
        return workOrderNameDoseValueMapper.deleteWorkOrderNameDoseValueByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除工单剂量信息
     * 
     * @param id 工单剂量主键
     * @return 结果
     */
    @Override
    public int deleteWorkOrderNameDoseValueById(Long id)
    {
        return workOrderNameDoseValueMapper.deleteWorkOrderNameDoseValueById(id);
    }

    @Override
    public List<WorkOrderNameDoseValue> getAll(Integer pageNumber, Integer lines, String overhaul_name) {
        return workOrderNameDoseValueMapper.getAll(pageNumber,lines,overhaul_name);
    }
}
